﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Logon.Master" Inherits="System.Web.Mvc.ViewPage<CourseSystem.Common.Models.LogOnModel>" %>
<%@ Import Namespace="CourseSystem.Common.Helpers" %>
<%@ Import Namespace="CourseSystem.Core.BLL" %>
<%@ Import Namespace="CourseSystem.Stat" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    登录
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <tr>
        <td rowspan="3">
            <img src="<%=ResolveUrl("~/Content/images/z_02.gif") %>" width="4" height="442" alt="">
        </td>
        <td width="401" height="439" rowspan="2" background="<%=ResolveUrl("~/Content/images/00002.jpg") %>">
            <img src="<%=ResolveUrl("~/"+CourseSettingBLL.Get().LoginImgLeft) %>" alt="" />
        </td>
        <td width="395" height="220" valign="bottom" background="<%=ResolveUrl("~/Content/images/z_04.gif") %>">
            <%using (Html.BeginForm("Logon", "Account", FormMethod.Post))
              {%>
            <table width="380" border="0" cellspacing="0" cellpadding="0">
                <tr>
                    <td width="22">
                        &nbsp;
                    </td>
                    <td width="358">
                        <table width="342" border="0" cellspacing="0" cellpadding="0">
                            <tr>
                                <td height="25">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td height="25">
                                    <table width="342" height="25" border="0" cellpadding="0" cellspacing="0">
                                        <tr class="style1">
                                            <td width="40" class="style2">
                                                账号：
                                            </td>
                                            <td width="162">
                                                <input type="text" name="Account" id="Account" style="width: 150px;">
                                            </td>
                                            <td width="140">
                                               <%-- <table width="52" height="25" border="0" cellpadding="0" cellspacing="0">
                                                    <tr>
                                                        <td background="<%=ResolveUrl("~/Content/images/0ew0002.jpg") %>">
                                                            <div align="center">
                                                                <strong class="style6"><a id="regA" href="javascript:;" class="style7">注册</a></strong></div>
                                                        </td>
                                                    </tr>
                                                </table>--%>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td height="10">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td height="25">
                                    <table width="342" height="25" border="0" cellpadding="0" cellspacing="0">
                                        <tr class="style1">
                                            <td width="40" class="style2">
                                                密码：
                                            </td>
                                            <td width="162">
                                                <input type="password" name="PassWord" id="PassWord" style="width: 150px;">
                                            </td>
                                            <td width="140">
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td height="10">
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td height="25">
                                    <table width="342" height="0" border="0" cellpadding="0" cellspacing="0">
                                        <tr>
                                            <td width="61" align="right">
                                                <input type="button" id="regA" value="注册" />
                                            </td>
                                             <td width="15">
                                                &nbsp;
                                            </td>
                                            <td width="80" height="25">
                                                <div align="center" class="style6">
                                                    <input type="submit" value="登录" />
                                                </div>
                                            </td>
                                            <td width="15">
                                                &nbsp;
                                            </td>
                                            <td width="80" align="left" >
                                                    <%=Html.ActionButton("参观", "GuessLogin")%>
                                            </td>
                                            <td width="15">
                                                &nbsp;
                                            </td>
                                            <td width="80">
                                                <%--<%=Html.ActionButton("我要评价", "GuessLogin")%>--%>
                                            </td>
                                            <td width="31">
                                                &nbsp;
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td height="35">
                                    &nbsp;
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
            <%}  %>
        </td>
    </tr>
    <tr>
        <td width="395" height="219" background="<%=ResolveUrl("~/Content/images/z_05.gif") %>">
            <table width="380" border="0" cellspacing="0" cellpadding="0">
                <tr>
                    <td width="23">
                        &nbsp;
                    </td>
                    <td width="357">
                        <table width="342" border="0" cellspacing="0" cellpadding="0">
                            <tr>
                                <td height="25" class="style1">
                                    <p class="style3">
                                        <a href="<%=Url.Action("Index","Stat") %>" class="style2">流量详细统计</a></p>
                                </td>
                            </tr>
                            <tr>
                                <td height="25" class="style2">
                                    总访问次数：<%=CourseSettingBLL.Get().Hits+IpStat.HitsAdd %>
                                </td>
                            </tr>
                            <tr>
                                <td height="25" class="style2">
                                    今日访问量（IP）：<%=CourseSettingBLL.Get().TodayIpHits %>
                                </td>
                            </tr>
                            <tr>
                                <td height="25" class="style2">
                                    在线人数：<%=UserOnlineStat.GetOnlineCount()%>
                                </td>
                            </tr>
                            <tr>
                                <td height="25" class="style2">
                                    峰值人数：<%=CourseSettingBLL.Get().MaxOnline%>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
        </td>
    </tr>
    <tr>
        <td colspan="2">
            <img src="<%=ResolveUrl("~/Content/images/z_06.gif") %>" width="796" height="3" alt="" />
        </td>
    </tr>
    <div id="RegDiv" title="注册新用户">
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HeaderContent" runat="server">
    <script type="text/javascript">
        $(function () {
            $("#RegDiv").dialog({
                autoOpen: false,
                height: 450,
                width: 500,
                modal: true,
                /* buttons: {
                "关闭": function () {
                $(this).dialog("close");
                }
                },*/
                close: function () {
                    // allFields.val("").removeClass("ui-state-error");
                }
            });



            $("#regA")
			.click(function () {
			    $("#RegDiv").html("loading...");
			    $("#RegDiv").load('<%=Url.Action("RegUc") %>');
			    $("#RegDiv").dialog("open");
			    return false;
			});
        });
    </script>
</asp:Content>
